#ifndef INTERFACE_H
#define INTERFACE_H
#include "Server.h"
#include <unistd.h>
class Interface {
public:
  Interface() : server(nullptr) {}
  void connect_to_server(Server *s);
  int welcome();
  void menu();
  int user_sign_in();
  int user_sign_up();
  bool admin_login();

  // FOR USER_SIGN_IN
  void user_logout();
  void user_view(cart *to_view = nullptr, bool price = false);
  void user_search();
  void user_add_cart();
  void user_pop_cart();
  void user_purchase();
  void user_menu();
  // FOR ADMIN_LOGIN
  void admin_logout();
  void admin_view();
  void admin_add();
  void admin_del();
  void admin_set();
  void admin_list();
  void admin_menu();

  // FOR USER_SIGN_UP
  void sign_up_success();
  void sign_up_fail();

  //23333333
  void feed_me();
private:
  Server *server;
};
#endif